home *** CD-ROM | disk | FTP | other *** search
/ Visual Basic Toolbox / Visual Basic Toolbox (P.I.E.)(1996).ISO / buttons / selvb20 / secaptio.frm < prev    next >
Text File  |  1995-06-18  |  10KB  |  352 lines

  1. VERSION 2.00
  2. Begin Form CaptionDemo 
  3.    BackColor       =   &H00C0C0C0&
  4.    BorderStyle     =   1  'Fixed Single
  5.    Caption         =   "Caption Demo"
  6.    ClientHeight    =   3300
  7.    ClientLeft      =   1695
  8.    ClientTop       =   6870
  9.    ClientWidth     =   7455
  10.    Height          =   3645
  11.    Left            =   1665
  12.    LinkTopic       =   "Form2"
  13.    MDIChild        =   -1  'True
  14.    ScaleHeight     =   3300
  15.    ScaleWidth      =   7455
  16.    Top             =   6555
  17.    Width           =   7515
  18.    Begin SELECTOR Selector1 
  19.       Angle           =   360
  20.       AutoAlign       =   -1  'True
  21.       AutoAngle       =   -1  'True
  22.       AutoOffset      =   -1  'True
  23.       AutoOffsetDistance=   0.4
  24.       AutoOffsetStyle =   1  ' 1 - Horizontal 
  25.       AutoRadius      =   0.6
  26.       AutoStartAngle  =   181
  27.       AutoStopAngle   =   360
  28.       BackgroundColor =   &H00C0C0C0&
  29.       BevelInner      =   1  ' 1 - Raised
  30.       BevelOuter      =   2  ' 2 - Inset
  31.       BevelWidth      =   2
  32.       BorderType      =   1  ' 1 - Bevel
  33.       BorderWidth     =   2
  34.       Captions        =   SECAPTIO.FRX:0000
  35.       FrameColor      =   &H00C0C0C0&
  36.       FrameScaleX     =   1.1
  37.       FrameScaleY     =   1.1
  38.       FrameStyle      =   2  ' 2 - Rectangle
  39.       Height          =   2940
  40.       Highlight       =   -1  'True
  41.       HighlightColor  =   &H00008000&
  42.       KnobColor       =   &H00000000&
  43.       KnobOriginX     =   0
  44.       KnobOriginY     =   0
  45.       KnobRadius      =   0.3
  46.       KnobStyle       =   1  ' 1 - Pointer
  47.       KnobUserDefined =   ""
  48.       Left            =   150
  49.       LineDisplay     =   -1  'True
  50.       LineInnerRadius =   0.35
  51.       LineThickness   =   2
  52.       MarkUserDefined =   ""
  53.       MouseControl    =   -1  'True
  54.       OutlineAlign    =   0  ' 0 - Left 
  55.       OutlineColor    =   &H00000000&
  56.       OutlineTitle    =   ""
  57.       OutlineWidth    =   0
  58.       Radius          =   0
  59.       TabIndex        =   23
  60.       Top             =   150
  61.       Value           =   4
  62.       Width           =   2910
  63.       XScale          =   0
  64.       YScale          =   0
  65.    End
  66.    Begin TextBox Text1 
  67.       Height          =   315
  68.       Left            =   3480
  69.       TabIndex        =   0
  70.       Text            =   " "
  71.       Top             =   2760
  72.       Width           =   3855
  73.    End
  74.    Begin HScrollBar HScroll1 
  75.       Height          =   225
  76.       Index           =   1
  77.       Left            =   3480
  78.       Max             =   140
  79.       Min             =   -140
  80.       TabIndex        =   10
  81.       Top             =   2070
  82.       Width           =   3885
  83.    End
  84.    Begin HScrollBar HScroll1 
  85.       Height          =   225
  86.       Index           =   0
  87.       Left            =   3480
  88.       Max             =   140
  89.       Min             =   -140
  90.       TabIndex        =   5
  91.       Top             =   1590
  92.       Width           =   3885
  93.    End
  94.    Begin Frame Frame1 
  95.       BackColor       =   &H00C0C0C0&
  96.       Caption         =   "Caption ID"
  97.       Height          =   1095
  98.       Left            =   3450
  99.       TabIndex        =   1
  100.       Top             =   60
  101.       Width           =   1215
  102.       Begin OptionButton Option1 
  103.          BackColor       =   &H00C0C0C0&
  104.          Caption         =   "2"
  105.          Height          =   255
  106.          Index           =   2
  107.          Left            =   360
  108.          TabIndex        =   4
  109.          TabStop         =   0   'False
  110.          Top             =   720
  111.          Width           =   615
  112.       End
  113.       Begin OptionButton Option1 
  114.          BackColor       =   &H00C0C0C0&
  115.          Caption         =   "1"
  116.          Height          =   255
  117.          Index           =   1
  118.          Left            =   360
  119.          TabIndex        =   3
  120.          TabStop         =   0   'False
  121.          Top             =   480
  122.          Width           =   615
  123.       End
  124.       Begin OptionButton Option1 
  125.          BackColor       =   &H00C0C0C0&
  126.          Caption         =   "0"
  127.          Height          =   255
  128.          Index           =   0
  129.          Left            =   360
  130.          TabIndex        =   2
  131.          Top             =   240
  132.          Value           =   -1  'True
  133.          Width           =   615
  134.       End
  135.    End
  136.    Begin Label Label1 
  137.       AutoSize        =   -1  'True
  138.       BackStyle       =   0  'Transparent
  139.       Caption         =   "Caption "
  140.       Height          =   195
  141.       Index           =   2
  142.       Left            =   3480
  143.       TabIndex        =   14
  144.       Top             =   2550
  145.       Width           =   720
  146.    End
  147.    Begin Label Colors 
  148.       BackColor       =   &H00004040&
  149.       Height          =   495
  150.       Index           =   9
  151.       Left            =   6840
  152.       TabIndex        =   8
  153.       Top             =   660
  154.       Width           =   465
  155.    End
  156.    Begin Label Colors 
  157.       BackColor       =   &H000080FF&
  158.       Height          =   495
  159.       Index           =   8
  160.       Left            =   6840
  161.       TabIndex        =   9
  162.       Top             =   150
  163.       Width           =   465
  164.    End
  165.    Begin Label Colors 
  166.       BackColor       =   &H00FF00FF&
  167.       Height          =   495
  168.       Index           =   7
  169.       Left            =   6360
  170.       TabIndex        =   17
  171.       Top             =   660
  172.       Width           =   465
  173.    End
  174.    Begin Label Colors 
  175.       BackColor       =   &H00FF0000&
  176.       Height          =   495
  177.       Index           =   6
  178.       Left            =   6360
  179.       TabIndex        =   18
  180.       Top             =   150
  181.       Width           =   465
  182.    End
  183.    Begin Label Colors 
  184.       BackColor       =   &H0000FFFF&
  185.       Height          =   495
  186.       Index           =   5
  187.       Left            =   5880
  188.       TabIndex        =   19
  189.       Top             =   660
  190.       Width           =   465
  191.    End
  192.    Begin Label Colors 
  193.       BackColor       =   &H0000FF00&
  194.       Height          =   495
  195.       Index           =   4
  196.       Left            =   5880
  197.       TabIndex        =   15
  198.       Top             =   150
  199.       Width           =   465
  200.    End
  201.    Begin Label Colors 
  202.       BackColor       =   &H000000FF&
  203.       Height          =   495
  204.       Index           =   3
  205.       Left            =   5400
  206.       TabIndex        =   22
  207.       Top             =   660
  208.       Width           =   465
  209.    End
  210.    Begin Label Colors 
  211.       BackColor       =   &H00FFFFFF&
  212.       Height          =   495
  213.       Index           =   2
  214.       Left            =   5400
  215.       TabIndex        =   21
  216.       Top             =   150
  217.       Width           =   465
  218.    End
  219.    Begin Label Colors 
  220.       BackColor       =   &H00808080&
  221.       Height          =   495
  222.       Index           =   1
  223.       Left            =   4920
  224.       TabIndex        =   20
  225.       Top             =   660
  226.       Width           =   465
  227.    End
  228.    Begin Label Colors 
  229.       BackColor       =   &H00000000&
  230.       Height          =   495
  231.       Index           =   0
  232.       Left            =   4920
  233.       TabIndex        =   16
  234.       Top             =   150
  235.       Width           =   465
  236.    End
  237.    Begin Label Label2 
  238.       Alignment       =   2  'Center
  239.       AutoSize        =   -1  'True
  240.       BackStyle       =   0  'Transparent
  241.       Caption         =   " "
  242.       Height          =   195
  243.       Index           =   2
  244.       Left            =   5325
  245.       TabIndex        =   13
  246.       Top             =   2730
  247.       Width           =   90
  248.    End
  249.    Begin Label Label2 
  250.       Alignment       =   2  'Center
  251.       AutoSize        =   -1  'True
  252.       BackStyle       =   0  'Transparent
  253.       Caption         =   " "
  254.       Height          =   195
  255.       Index           =   1
  256.       Left            =   5325
  257.       TabIndex        =   12
  258.       Top             =   1800
  259.       Width           =   90
  260.    End
  261.    Begin Label Label1 
  262.       AutoSize        =   -1  'True
  263.       BackStyle       =   0  'Transparent
  264.       Caption         =   "Y Position:"
  265.       Height          =   195
  266.       Index           =   1
  267.       Left            =   3480
  268.       TabIndex        =   11
  269.       Top             =   1860
  270.       Width           =   930
  271.    End
  272.    Begin Label Label1 
  273.       AutoSize        =   -1  'True
  274.       BackStyle       =   0  'Transparent
  275.       Caption         =   "X Position:"
  276.       Height          =   195
  277.       Index           =   0
  278.       Left            =   3480
  279.       TabIndex        =   6
  280.       Top             =   1380
  281.       Width           =   930
  282.    End
  283.    Begin Label Label2 
  284.       Alignment       =   2  'Center
  285.       AutoSize        =   -1  'True
  286.       BackStyle       =   0  'Transparent
  287.       Caption         =   " "
  288.       Height          =   195
  289.       Index           =   0
  290.       Left            =   5325
  291.       TabIndex        =   7
  292.       Top             =   1320
  293.       Width           =   90
  294.    End
  295. End
  296.  
  297. Sub Colors_Click (index As Integer)
  298.  
  299.     Selector1.captionColor = colors(index).BackColor
  300.  
  301. End Sub
  302.  
  303. Sub Form_Load ()
  304.  
  305.     hscroll1(0) = Selector1.captionX * 100
  306.     hscroll1(1) = Selector1.CaptionY * 100
  307.     text1 = Selector1.caption
  308.  
  309. End Sub
  310.  
  311. Sub HScroll1_Change (index As Integer)
  312.  
  313.     Select Case index
  314.         Case 0
  315.             Selector1.captionX = hscroll1(0) / 100
  316.             label2(0) = hscroll1(0) / 100
  317.         Case 1
  318.             Selector1.CaptionY = hscroll1(1) / 100
  319.             label2(1) = hscroll1(1) / 100
  320.     End Select
  321.  
  322. End Sub
  323.  
  324. Sub HScroll1_Scroll (index As Integer)
  325.  
  326.     Select Case index
  327.         Case 0
  328.             Selector1.captionX = hscroll1(0) / 100
  329.             label2(0) = hscroll1(0) / 100
  330.         Case 1
  331.             Selector1.CaptionY = hscroll1(1) / 100
  332.             label2(1) = hscroll1(1) / 100
  333.     End Select
  334.  
  335. End Sub
  336.  
  337. Sub Option1_Click (index As Integer)
  338.  
  339.     Selector1.captionID = index
  340.     hscroll1(0) = Selector1.captionX * 100
  341.     hscroll1(1) = Selector1.CaptionY * 100
  342.     text1 = Selector1.caption
  343.  
  344. End Sub
  345.  
  346. Sub Text1_Change ()
  347.  
  348.     Selector1.caption = text1
  349.  
  350. End Sub
  351.  
  352.